<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'addPicture.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
<script type="text/javascript" src="js/upload.js"></script>
  </head>
  
  <body>
    <form action="<%=basePath %>picture/picture_savePicture" method="post" enctype="multipart/form-data">
    	<input name="handBook.id" value="${handBook.id}" type="hidden">
    	<input name="handBook.userId" value="${user.id}"  type="hidden">
    	<input name="user.userName" value="${user.userName}" type="hidden">
    	<input name="count" value="${count}"  type="hidden">
    	<s:if test="count == 11">
    		该手册的内容图片已经上传完成，无法再次上传新的图片，请您谅解。
    		<a href="<%=basePath %>books/books_bookList?handBook.userId=${user.id}">返回列表</a>
    	</s:if>
    	<s:else>
    		请选择图片：<input type="file" name="upload"  onChange="c(this)" /><br>
    		<input type="submit" value="提交">
    		<a href="<%=basePath %>books/books_bookList?handBook.userId=${user.id}">返回</a>
    	</s:else>
    </form>
  </body>
</html>
